package com.example.project_01.service;

import com.example.project_01.commons.Result;
import com.example.project_01.model.CityModel;
import com.github.pagehelper.PageInfo;

public interface CityService {

    //获取所有城市信息并分页，name不为空则模糊查询,当pn和size为null,则整页查询
    PageInfo<CityModel> getCityWithPage(Integer pn,Integer size, String name);

    //根据id查找一个城市信息
    Result getCityById(Integer id);

    //添加一个城市
    Result addCity(Integer cityNumber);

    //查询城市是否存在
    int checkCityByNum(Integer cityName);

    //根据id删除城市
    Result deleteCityById(Integer id);


}
